﻿using Microsoft.EntityFrameworkCore;
using Volo.Abp.Data;
using Volo.Abp.EntityFrameworkCore;

namespace Himp.Setl.EntityFrameworkCore;

[ConnectionStringName(SetlDbProperties.ConnectionStringName)]
public class SetlDbContext : AbpDbContext<SetlDbContext>, ISetlDbContext
{
    public DbSet<SetlType> SetlTypes { get; set; }

    /// <summary>
    /// 
    /// </summary>
    public DbSet<InvUsedRec> InvUsedRecs { get; set; }

    public SetlDbContext(DbContextOptions<SetlDbContext> options)
        : base(options)
    {

    }

    protected override void OnModelCreating(ModelBuilder builder)
    {
        base.OnModelCreating(builder);

        builder.ConfigureSetl();
    }
}
